package com.gitee.tanmingjian.httptunnel.core.bean;

import java.util.Objects;

public class QueryResult {

    private ResultSetHeader resultSetHeader;

    private Object resultSetBody;

    private Boolean hasNext;

    public ResultSetHeader getResultSetHeader() {
        return resultSetHeader;
    }

    public void setResultSetHeader(ResultSetHeader resultSetHeader) {
        this.resultSetHeader = resultSetHeader;
    }

    public Object getResultSetBody() {
        return resultSetBody;
    }

    public void setResultSetBody(Object resultSetBody) {
        this.resultSetBody = resultSetBody;
    }

    public Boolean getHasNext() {
        return hasNext;
    }

    public void setHasNext(Boolean hasNext) {
        this.hasNext = hasNext;
    }

    @Override
    public boolean equals(Object o) {
        if (this == o) return true;
        if (o == null || getClass() != o.getClass()) return false;
        QueryResult that = (QueryResult) o;
        return Objects.equals(resultSetHeader, that.resultSetHeader) && Objects.equals(resultSetBody, that.resultSetBody) && Objects.equals(hasNext, that.hasNext);
    }

    @Override
    public int hashCode() {
        return Objects.hash(resultSetHeader, resultSetBody, hasNext);
    }

    @Override
    public String toString() {
        return "QueryResult{" +
                "resultSetHeader=" + resultSetHeader +
                ", resultSetBody=" + resultSetBody +
                ", hasNext=" + hasNext +
                '}';
    }
}
